﻿<%@ Page CodeFileBaseClass="AliCMS.Lib.SystemPageBase" %>
<section data-page="type_add" data-title="添加类型" data-lang="<%=ContentLang%>" data-module-path="<%=Manager.GetModulePath("AliCMS.AdModule")%>">
	<dl class="path1">
		<dt><span>您的位置：</span>添加类型</dt>
		<dd>
			<select data-ali-widget="combo" data-class="<%=ContentLang%>Font">
				<ali:List Mark="System" Object="Language" Source="Manager.Languages">
					<ali:Record>
						<%If Convert.ToString(Ab) == ContentLang%>
							<option value="<%=Ab%>" selected><%=[AliCMS.SystemModule.Alias.Language.Name + PageLang]%></option>
						<%Else%>
							<option value="<%=Ab%>"><%=[AliCMS.SystemModule.Alias.Language.Name + PageLang]%></option>
						<%EndIf%>
					</ali:Record>
				</ali:List>
			</select>
		</dd>
	</dl>
	<form action="?Lang=<%=ContentLang%>" class="post">
		<div class="post-body">
			<div class="ali-tabs" data-event="click">
				<div class="ali-tabs-header">
					<div class="ali-tabs-nav-container">
						<ul>
							<li><a href="list.aspx?Lang=<%=ContentLang%>" target="ali-navtab">类型列表</a></li>
							<li class="ali-active"><a>添加类型</a></li>
						</ul>				
					</div>
				</div>
				<div class="ali-tabs-body">
					<div class="ali-tabs-panel"></div>
					<div class="ali-tabs-panel">
						<table class="post-table margin2">			
							<tr>
								<th>名称：</th>
								<td>
									<input type="text" name="Name" size="40" maxlength="50" class="ali-input <%=ContentLang%>Font">
									<label><input type="checkbox" data-operation="CheckGuid">Guid：</label><input type="text" name="ID" size="40" maxlength="40" disabled class="ali-input ali-disabled">
								</td>
							</tr>
							<tr>
								<th>调用代码：</th>
								<td>
									<textarea name="InvokeCode" cols="70" rows="10" wrap="off" class="ali-input"></textarea>
								</td>
							</tr>
							<tr>
								<th>描述：</th>
								<td>
									<textarea name="Description" cols="70" rows="10" wrap="off" class="ali-input  <%=ContentLang%>Font"></textarea>
								</td>
							</tr>
							<tr>
								<th>模板(swf)：</th>
								<td>
									<input type="text" name="Template" size="55" class="ali-input"><a class="ali-button ali-uploader">浏览...</a>
									<input type="hidden" name="TemplateAllowedType" value="swf">
								</td>
							</tr>
							<tr>
								<th>数据文件名称（含扩展名）：</th>
								<td><input type="text" name="DataFileName" size="30" maxlength="50" class="ali-input"></td>
							</tr>
							<tr>
								<th>数据模板：</th>
								<td>
									<textarea name="DataTemplate" cols="70" rows="10" wrap="off" class="ali-input"></textarea>
								</td>
							</tr>
							<tr>
								<td colspan="2">
									<ul>
										<li>“数据模板”和“调用代码”有特有的格式：</li>
										<li>当前广告实例ID：&lt;%=InstanceID%&gt;</li>
										<li>获取类型的数据：&lt;%=属性名称%&gt;</li>
										<li>类型的属性有：ID,InnerID,Name,Description,TemplateFilePath</li>
										<li>获取类型资源路径：&lt;%=Resource[文件名称]%&gt;</li>
										<li>获取广告位的数据：&lt;%=Position[属性名称]%&gt;</li>
										<li>广告位的属性有：ID,InnerID,DataFilePath,Name,Width,Height,SketchMap,Title,Image,URL,Code,Description</li>
										<li>获取广告的数据：&lt;%=Ad[顺序号][属性名称]%&gt;</li>
										<li>广告的属性有：ID,InnerID,Title,Image,Width,Height,URL,Code</li>
									</ul>
								</td>
							</tr>
						</table>
					</div>
				</div>
				<div class="ali-tabs-bottom"><b></b></div>
			</div>
		</div>
		<div class="post-footer"><button type="submit" class="ali-button">添 加</button></div>
	</form>
</section>